<%
  java.util.Vector strSearchNames = (java.util.Vector)pageContext.getAttribute("searchnames");
  if (strSearchNames == null) strSearchNames = new java.util.Vector();
  String strCurSearchName = (String)pageContext.getAttribute("searchname");
  if (strCurSearchName == null) strCurSearchName = "";
  String strCurSearchValue = (String)session.getAttribute("searchvalue");
  if (strCurSearchValue == null) strCurSearchValue = "";
  
  String strCurSearchValue1 = "";
  String strCurSearchValue2 = "";
  String comDisplay = "";
  String speDisplay = "none";
  
  for (int i = 0; i < strSearchNames.size(); i++)
  {
    java.util.HashMap tmpHash = (java.util.HashMap)strSearchNames.elementAt(i);
    String colName = (String)tmpHash.get("columnname");
    String colType = (String)tmpHash.get("columntype");
    
    if (strCurSearchName.length() == 0) strCurSearchName = colName;
    
    if (strCurSearchName.equals(colName))
    {
      if (!colType.equalsIgnoreCase("varchar"))
      {
        comDisplay = "none";
        speDisplay = "";
      }
      
      int csvp = strCurSearchValue.indexOf("^");
      if (csvp != -1 && !colType.equalsIgnoreCase("varchar"))
      {
        strCurSearchValue1 = strCurSearchValue.substring(0,csvp);
        strCurSearchValue2 = strCurSearchValue.substring(csvp + 1);  
        strCurSearchValue = "";
      }
      if (csvp != -1 && colType.equalsIgnoreCase("date"))
      {
        strCurSearchValue1 = OvalTools.dateToString(strCurSearchValue1,(String)session.getAttribute("dateformat"));
        strCurSearchValue2 = OvalTools.dateToString(strCurSearchValue2,(String)session.getAttribute("dateformat"));   
  		  strCurSearchValue = "";
      }
    }
  }
%>
